(function () {
    // 信息流广告
    NewsFlowSad = function (options) {
        var self = this;
        var defaultOption = {
            $newsFlow: So.newsFlow.$newsFlow,   // 流最外层容器
            showId: So.newsFlow.showId,   // 广告统计标示
            eventMark: So.newsFlow.eventMark,  // 事件标示
            logMark: So.newsFlow.logMark,  // 日志标示
            type: So.newsFlow.type,
            qcmsData: null, // qcms运营位数据
            showQcmsData: false, // 是否展示qcms运营位
            startPos: So.newsFlow.flowQcms.resultAdStart,	// 广告起始位置
            step: So.newsFlow.flowQcms.resultAdStep,	// 广告间隔
            onlyShowSingleImg: false,   // 只展示单图广告
            onlyShowSingleManyImg: false, // 只展示单图和多图广告
            jumpShow: true,   // 是否不同间隔插入，step = 3, 间隔3 间隔2 间隔3 间隔2....
            guid: So.comm.guid,  // 用户唯一标示
            template: '', // 广告模板
            video: {    // 视频广告
                height: 201  // 图片高度
            },
            bigImg: {  // 大图广告
                width: 540,
                height: 201
            },
            squareImg: {    // 方图广告
                count: 4,
                width: 132,
                height: 132,
            },
            bannerImg: {    // qcms运营位，banner图
                width: 540,
                height: 64,
            },
            manyImg: {  // 多图广告
                count: 4,   // >=4为多图
                width: 132,
                height: 84
            },
            singleImg: {    // 单图配置
                width: 132,
                height: 84,
                titleLength: 100
            },
            insertCb: $.noop    // 插入广告后回调
        };
        self.options = $.extend(true, {}, defaultOption, options);
        self.currPos = self.options.startPos; // 最后一条广告的位置
        self.html = []; // 待用广告dom
        self.page = 1;  // 第几次取广告
        self.timer; // 请求广告间timer
        self.timerVideo; // 视频播放timer
        self.deck = true;   // 间隔插入标示
        self.delCount = 20; // localStorage最多保存20条
        self.mouseDownTime = 0;
        self.mouseUpTime = 0;

        self.init();
    }

    NewsFlowSad.Tools = {
        checkImg: function () {// 图片加载失败，显示背景图
            var img = event.srcElement;
            $(img).remove();
            img.onerror = null;
        },
        formatSeconds: function (seconds) {
            var time = [
                parseInt(seconds / 60 / 60),
                parseInt(seconds / 60 % 60),
                parseInt(seconds % 60)
            ];
            time[0] === 0 && time.shift();
            return time.join(':').replace(/\b(\d)\b/g, '0$1');
        },
        log: So.lib.log,    // 业务自身打点
        cutStr: So.lib.cutStr,  // 字符串截断
        template: So.lib.template,  // 模板解析
        observer: So.lib.observer,  // observer
        isVisible: So.lib.isVisible1,   // dom是否在可视区域内
        soLocalStorage: So.lib.soLocalStorage   // local storage
    };

    NewsFlowSad.prototype = {
        init: function () {
            var self = this;
            self.options.showQcmsData && self.clearUpQcmsData();
            self.bindEvent();
            self.insert();
        },
        bindEvent: function () {
            var self = this;
            var $newsFlow = self.options.$newsFlow;
            var eventMark = self.options.eventMark;

            // 订阅事件
            NewsFlowSad.Tools.observer.subscribe(eventMark + '.rendered', function () {
                self.insert(self);
            });
            NewsFlowSad.Tools.observer.subscribe(eventMark + '.scroll', function (noReverse) {
                self.scrollEevent(self, noReverse);
            });

            $newsFlow.on('mousedown', 'li[data-from=sad]', function () {    // 点击打点使用
                self.mouseDownTime = + new Date();
            }).on('mouseup', 'li[data-from=sad]', function (e) {    // 点击打点使用
                self.mouseUpTime = + new Date();

                var $li = $(this);
                var $target = $(e.target);
                var $a = $target.closest('a');

                if ($a.length && $a.attr('data-href')) {
                    var x = Math.abs(parseInt($target.offset().left - $li.offset().left + e.offsetX));
                    var y = Math.abs(parseInt($target.offset().top - $li.offset().top + e.offsetY));
                    $a.attr('href', self.macro($a.attr('data-href'), x, y, $li.width(), $li.height()));
                    self.sendAdLog(self.macro($li.data('clktk'), x, y, $li.width(), $li.height()));
                    self.sendLog({
                        type: 'sad-click',
                        pos: $li.index() + 1,
                        value: $target.attr('data-log'),
                    });
                }
            }).on('click', 'li[data-from=sad] .close-list a', function (e) {	// 关闭选项
                var $li = $(this).closest('li');
                var $target = $(e.target);

                $li.data('clstk') && self.sendAdLog(self.macroDel($li.data('clstk'), $target.attr('data-val')));
                NewsFlowSad.Tools.observer.publish(eventMark + '.addNews');
                self.sendLog({ type: 'close-sad', pos: $li.index() + 1, value: $target.attr('data-val') });
                self.delAd($li);
            }).on('click', 'li[data-from=sad] .horn', function (e) {	// 喇叭
                var video = $(this).closest('li').find('video')[0];
                var $target = $(e.target);

                if ($target.hasClass('open')) {   // 关闭声音
                    $target.removeClass('open');
                    video.muted = true;
                } else {   // 打开声音
                    $newsFlow.find('.horn').removeClass('open');
                    $target.addClass('open');
                    $.each($newsFlow.find('video'), function (key, item) {  // 所有喇叭静音
                        item.muted = true;
                    });
                    video.muted = false;
                }
            }).on('click', 'li[data-from=sad] .play', function (e) {	// 播放按钮
                var $li = $(this).closest('li');
                var video = $li.find('video')[0];
                var $this = $(this);

                self.videoPlayTime($this, video);

                if (video.paused) {
                    video.play();
                    $this.addClass('paused');
                    $li.removeClass('manual-stop');
                } else {
                    video.pause();
                    $this.removeClass('paused');
                    $li.addClass('manual-stop');
                }
            }).on('click', 'li[data-from=sad-qcms]', function (e) { // qcms运营位
                var $target = $(e.target);
                var $li = $(this);

                if ($target.is('.close-list a')) {	// 删除qcms运营位
                    // var title = $li.attr('data-title');
                    // var qcmsData = NewsFlowSad.Tools.soLocalStorage.getItem('delAd') || JSON.stringify([]);
                    // qcmsData = JSON.parse(qcmsData);
                    // if (qcmsData.length == self.delCount) {
                    //     qcmsData.shift();
                    // }
                    // qcmsData.push(title);
                    // NewsFlowSad.Tools.soLocalStorage.setItem('delAd', JSON.stringify(qcmsData));
                    self.delAd($li);
                    self.sendLog({ type: 'close-qcms-sad' });
                } else if ($target.closest('a').length) {	// qcms运营位打点
                    self.sendLog({
                        type: 'sad-qcms-click',
                        pos: $li.index() + 1,
                        value: $target.attr('data-log')
                    });
                }
            });
        },
        videoPlayTime: function ($play, video) {
            video.ontimeupdate = function () {
                $play.find('.time').text(NewsFlowSad.Tools.formatSeconds(Math.floor(video.duration - video.currentTime)));
            };
        },
        calculateAdPos: function (isReset) {    // 计算广告插入位置
            var self = this;
            var options = self.options;

            if (isReset) {
                self.currPos = options.startPos;
            } else {
                self.currPos = options.$newsFlow.find('li[data-from="sad"]:last').index() + options.step + 1;
            }
        },
        delAd: function ($li) {    // 删除单条广告
            var self = this;
            var $newsFlow = self.options.$newsFlow;
            var eventMark = self.options.eventMark;

            $li.slideUp(100, function () {
                $li.remove();
                if (!$newsFlow.find('li').length) {
                    NewsFlowSad.Tools.observer.publish(eventMark + '.closeFlow');
                }
                NewsFlowSad.Tools.observer.publish(eventMark + '.flowHeightChange');
                self.calculateAdPos();
            });
        },
        macroDel: function (str, val) { // 删除宏替换
            return str.replace(/__DISLIKE_RULE_ID__|__DISLIKE_TAG__/g, function (f) {
                return {
                    '__DISLIKE_RULE_ID__': val,
                    '__DISLIKE_TAG__': '不感兴趣',
                }[f];
            });
        },
        macro: function (str, x, y, w, h) {   // 点击宏替换
            var self = this;
            return str.replace(/__OFFSET_X__|__OFFSET_Y__|__EVENT_TIME_START__|__EVENT_TIME_END__|__ADSPACE_W__|__ADSPACE_H__/g, function (f) {
                return {
                    '__OFFSET_X__': x,
                    '__OFFSET_Y__': y,
                    '__EVENT_TIME_START__': self.mouseDownTime,
                    '__EVENT_TIME_END__': self.mouseUpTime,
                    '__ADSPACE_W__': w,
                    '__ADSPACE_H__': h
                }[f];
            });
        },
        clearUpQcmsData: function () {  // 运营位数据
            var self = this;
            var options = self.options;
            var qcmsData = options.qcmsData;
            // test
            // qcmsData = {
            //     title: "test标题",
            //     desc: "test摘要",
            //     curl: "http://www.so.com",
            //     src: "test来源",
            //     isBanner: '1',
            //     isHome: '0',    // 首页结果页共用，传入之前就处理好数据，直接显示
            //     isShowAd: '1',
            //     pos: '0',
            //     imgs: [
            //         {
            //             curl: 'img-url-1',
            //             img: 'http://p9.qhimg.com/t01077da7bc40d3852a.png'
            //         },
            //         {
            //             curl: 'img-url-1',
            //             img: 'http://p9.qhimg.com/t01077da7bc40d3852a.png'
            //         },
            //         {
            //             curl: 'img-url-1',
            //             img: 'http://p9.qhimg.com/t01077da7bc40d3852a.png'
            //         },
            //         {
            //             curl: '',
            //             img: ''
            //         },
            //     ]
            // };

            if (!qcmsData) {
                return;
            }

            // 已删除广告
            var delData = NewsFlowSad.Tools.soLocalStorage.getItem('delAd');
            delData = delData ? JSON.parse(delData) : [];
            if (!qcmsData || ~$.inArray(qcmsData.title, delData)) {
                return;
            }
            delData.push(qcmsData.title);   // 只展现一次
            NewsFlowSad.Tools.soLocalStorage.setItem('delAd', JSON.stringify(delData));

            var finallyData = {
                from: 'sad-qcms',
                curl: qcmsData.curl,
                isBanner: parseInt(qcmsData.isBanner),
                isShowAd: parseInt(qcmsData.isShowAd),
                title: qcmsData.title || '',
                desc: qcmsData.desc || '',
                src: qcmsData.src || ''
            };

            // qcms数据格式: 始终返回4条图片，小于四条按单图展示
            var isSingle = false;
            for (var i = 0, len = qcmsData.imgs.length; i < len; i++) {
                if (qcmsData.imgs[i].img == '' || qcmsData.imgs[i].curl == '') {
                    isSingle = true;
                    break;
                }
            }

            // 为了与广告数据保持一致，单图数据放入img，多图放入assets
            if (finallyData.isBanner || isSingle || options.onlyShowSingleImg) {
                finallyData.img = qcmsData.imgs[0].img;
            } else {
                finallyData.assets = qcmsData.imgs;
            }

            if (finallyData.img || finallyData.assets) {
                self.currPos = parseInt(qcmsData.pos);
            }

            self.sendLog({ type: 'show-qcms-sad' });

            self.clearUpData([finallyData]);
        },
        sendLog: function (params) {    // 发送打点
            var options = this.options;
            NewsFlowSad.Tools.log(options.logMark, $.extend({}, {
                abid: options.$newsFlow.attr('data-abtest-id'),
                dataType: options.type
            }, params));
        },
        sendAdLog: function (data) {    // 发送商业化打点
            if (!data) return;

            data = data.split('||');
            window.sadLog = {};
            var log;
            for (var j = 0, len = data.length; j < len; j++) {
                log = 'log_' + +(new Date);
                sadLog[log] = new Image;
                sadLog[log].onload = sadLog[log].onerror = function () {
                    delete sadLog[log];
                }
                sadLog[log].src = data[j];
            }
        },
        imptkLog: function (self) {	// 曝光打点
            self = self || this;
            var options = self.options;
            $.each(options.$newsFlow.find('li[data-from="sad"]'), function (i, ad) {
                var $ad = $(ad);
                if (!$ad.data('imptked') && NewsFlowSad.Tools.isVisible($ad[0])) {
                    $ad.data('imptked', 1);
                    self.sendLog({ type: 'sad-show' });
                    self.sendAdLog($ad.data('imptk'));
                }
            });
        },
        scrollEevent: function (self, noReverse) {
            self = self || this;
            var options = self.options;
            var isLock = false;

            self.imptkLog(self);

            clearTimeout(self.timerVideo);
            var $li = options.$newsFlow.find('li[data-from="sad"]');
            $li = noReverse ? $($li.get().reverse()) : $li;    // 根据鼠标滚动的方向，调整数组

            self.timerVideo = setTimeout(function () {
                $.each($li, function (i, ad) {
                    var $ad = $(ad);
                    var $video = $ad.find('video');
                    var video = $video[0];
                    var $play = $ad.find('.play');
                    if (!$ad.hasClass('manual-stop') && $video.length) {
                        var position = ad.getBoundingClientRect();
                        if (!isLock && NewsFlowSad.Tools.isVisible(ad) && position.top > 30 && $(window).height() - position.bottom > -100) {
                            $play.addClass('paused');
                            video.play();
                            self.videoPlayTime($play, video);
                            isLock = true;
                        } else {
                            $play.removeClass('paused');
                            video.pause();
                        }
                    }
                });
            }, 40);
        },
        insert: function (self) {   // 插入广告
            self = self || this;
            var html = self.html;
            var currPos = self.currPos;
            var options = self.options;
            var step = options.step;
            var $newsFlow = options.$newsFlow;

            // 待用广告dom小于2条，就去请求数据
            if (html.length < 2) {
                clearTimeout(self.timer);
                self.timer = setTimeout(function () {
                    self.getData(self);
                }, 1000);
            }

            if ($newsFlow.find('li:not([class*=to-front])').length - (currPos + 1) >= 0 && html.length > 0) {
                $newsFlow.find('li:not([class*=to-front]):eq(' + currPos + ')').before(html.shift());
                if (self.deck && options.jumpShow) {
                    self.currPos += step;
                    self.deck = false;
                } else {
                    self.currPos += step + 1;
                    self.deck = true;
                }

                self.insert();
                self.scrollEevent(self, false);
                options.insertCb();
            }
        },
        clearUpData: function (sData) {
            var self = this;
            var options = self.options;
            var item = {};

            for (var i = 0, len = sData.length; i < len; i++) {
                var sTitle = sData[i].title;
                item = {
                    img: [],
                    imgWidth: 0,
                    imgHeight: 0,
                    liCoversClass: '',
                    url: sData[i].curl,
                    source: sData[i].src,
                    title: sTitle,	// 默认多图的长度
                    titleFull: sTitle,
                    imptk: sData[i].imptk && sData[i].imptk.join('||'),
                    clktk: sData[i].clktk && sData[i].clktk.join('||'),
                    clstk: sData[i].clstk && sData[i].clstk.join('||'),
                    from: 'sad',
                    sadTxt: '<span class="txt">广告</span>',
                    type: '',
                    duration: '00:00'
                };

                if (!options.onlyShowSingleImg && !options.onlyShowSingleManyImg) {
                    switch (sData[i].type) {
                        case 4:
                            if (!/msie (6|7|8|9)/gi.test(navigator.userAgent)) {
                                item.type = 'video';
                            } else {
                                item.type = 'bigImg';
                            }
                            break;
                        case 3:
                            item.type = 'bigImg';
                            break;
                        case 2:
                            if (sData[i].assets) {
                                var asset = sData[i].assets[0];
                                if (asset && asset.imgw && asset.imgh === asset.imgw) {
                                    item.type = 'squareImg';
                                }
                            }
                            break;
                    }
                }

                if (sData[i].isShowAd === 0) {
                    item.sadTxt = '';
                }

                if (sData[i].from) {
                    item.from = sData[i].from;
                    item.liCoversClass = item.from;
                }

                var sAssets = sData[i].assets || [];
                var sImg = sData[i].img || '';

                if (item.type == 'video' && !options.onlyShowSingleManyImg) { // 视频
                    item.liCoversClass += ' sad-video';
                    item.imgHeight = options.video.height;
                    if (sData[i].duration) {
                        item.duration = NewsFlowSad.Tools.formatSeconds(sData[i].duration);
                    }

                    sImg = sData[i].video;

                    item.img[0] = { style: '', url: item.url, src: sImg };
                } else if (item.type == 'bigImg' && !options.onlyShowSingleManyImg) { // 大图
                    item.liCoversClass += ' big-img';
                    item.imgWidth = options.bigImg.width;
                    item.imgHeight = options.bigImg.height;

                    sImg = sData[i].img;

                    item.img[0] = { style: ' class="anim"', url: item.url, src: sImg };
                } else if (item.type == 'squareImg' && sAssets.length >= options.squareImg.count && !options.onlyShowSingleManyImg) { // 方图多图
                    item.liCoversClass += ' square-img';
                    item.imgWidth = options.squareImg.width;
                    item.imgHeight = options.squareImg.height;
                    for (var c = 0, cLen = options.squareImg.count; c < cLen; c++) {
                        item.img[c] = { style: ' class="anim"', url: sAssets[c].curl, src: sAssets[c].img };
                    }
                } else if (sData[i].isBanner) {    // 运营位banner图
                    item.liCoversClass += ' banner-img';
                    item.imgWidth = options.bannerImg.width;
                    item.imgHeight = options.bannerImg.height;

                    item.img[0] = { style: ' class="anim"', url: item.url, src: sImg };
                } else if (sAssets.length >= options.manyImg.count && !options.onlyShowSingleImg) {	// 多图
                    item.type = 'manyImg';
                    item.imgWidth = options.manyImg.width;
                    item.imgHeight = options.manyImg.height;
                    for (var c = 0, cLen = options.manyImg.count; c < cLen; c++) {
                        item.img[c] = { style: ' class="anim"', url: sAssets[c].curl, src: sAssets[c].img };
                    }
                } else if (sImg) {	// 单图
                    item.type = 'singleImg';
                    item.liCoversClass += ' single-img';
                    item.imgWidth = options.singleImg.width;
                    item.imgHeight = options.singleImg.height;
                    item.img[0] = { style: ' class="anim"', url: item.url, src: sImg };
                    item.title = NewsFlowSad.Tools.cutStr(sTitle, options.singleImg.titleLength);
                }

                if (!item.img.length) { continue }

                self.html.push(NewsFlowSad.Tools.template(options.template, $.extend(item, { tplType: 'sad' })));
            }
        },
        getData: function (self) {
            var options = self.options;
            $.ajax({
                url: location.protocol == 'https:' ? '//show-g.mediav.com/s?scheme=https' : '//show.g.mediav.com/s',
                type: 'get',
                jsonp: 'jsonp',
                dataType: 'jsonp',
                data: {
                    of: 4,
                    type: 1,
                    newf: 1,
                    impct: 8,
                    uid: options.guid,
                    reqtimes: self.page,
                    showid: options.showId,
                    refurl: document.referrer
                },
                success: function (sData) {
                    // test
                    // sData = { "ads": [{ "assets": [{ "curl": "http://ssxd.mediav.com/s?type=3&r=20&pinfo=&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&price=AAAAAFk+C9oAAAAAAAeTu1p/gsdXul6zQeMu3w==&finfo=DAABCAABAAABvggAAgAAADYEAAM/f/Lkjopx3gAIAAIAAAADCgADPra+UTCr9hUIAAQAAAA2BgAGLCMIAAgARA3gCgAJAAAAAACGABIGAAoAAAA&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=FZDlMhWok9IBFbqM1A4ViqHrRxUEFSIW9puwwxUWzJPVuryU37Z9NAIWpICwCCUGFcPgoLsDFfABFQAA&clickid=75327557001&csign=70df286fcbe7a60b&url=http%3A%2F%2Fwww%2Ehejianzhiyang%2Ecom", "img": "http://s3m.mediav.com/galileo/dcb56800ac87350cbdbef62e69704032.gif " }, { "curl": "http://ssxd.mediav.com/s?type=2&r=20&pinfo=&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&price=AAAAAFk+C9oAAAAAAAeTu1p/gsdXul6zQeMu3w==&finfo=DAABCAABAAABvggAAgAAADYEAAM/f/Lkjopx3gAIAAIAAAADCgADPra+UTCr9hUIAAQAAAA2BgAGLCMIAAgARA3gCgAJAAAAAACGABIGAAoAAAA&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=FZDlMhWok9IBFbqM1A4ViqHrRxUEFSIW9puwwxUWzJPVuryU37Z9NAIWpICwCCUGFcPgoLsDFfABFQAA&clickid=75327557002&csign=70df286fcbe7a60b&url=http%3A%2F%2Fwww%2Ehejianzhiyang%2Ecom", "img": "http://s3m.mediav.com/galileo/76b6a15d2658044b716b2e304b2e5f85.jpg" }, { "curl": "http://ssxd.mediav.com/s?type=2&r=20&pinfo=&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&price=AAAAAFk+C9oAAAAAAAeTu1p/gsdXul6zQeMu3w==&finfo=DAABCAABAAABvggAAgAAADYEAAM/f/Lkjopx3gAIAAIAAAADCgADPra+UTCr9hUIAAQAAAA2BgAGLCMIAAgARA3gCgAJAAAAAACGABIGAAoAAAA&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=FZDlMhWok9IBFbqM1A4ViqHrRxUEFSIW9puwwxUWzJPVuryU37Z9NAIWpICwCCUGFcPgoLsDFfABFQAA&clickid=75327557003&csign=70df286fcbe7a60b&url=http%3A%2F%2Fwww%2Ehejianzhiyang%2Ecom", "img": "http://s3m.mediav.com/galileo/a65f3070bfcbbd328e1580e6ae756d7a.jpg" }, { "curl": "http://ssxd.mediav.com/s?type=2&r=20&pinfo=&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&price=AAAAAFk+C9oAAAAAAAeTu1p/gsdXul6zQeMu3w==&finfo=DAABCAABAAABvggAAgAAADYEAAM/f/Lkjopx3gAIAAIAAAADCgADPra+UTCr9hUIAAQAAAA2BgAGLCMIAAgARA3gCgAJAAAAAACGABIGAAoAAAA&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=FZDlMhWok9IBFbqM1A4ViqHrRxUEFSIW9puwwxUWzJPVuryU37Z9NAIWpICwCCUGFcPgoLsDFfABFQAA&clickid=75327557004&csign=70df286fcbe7a60b&url=http%3A%2F%2Fwww%2Ehejianzhiyang%2Ecom", "img": "http://s3m.mediav.com/galileo/3ca4acc8c132197be34ba468ab7467ea.jpg" }], "clktk": ["http://max-l.mediav.com/rtb?type=3&d=100&b=116628b68d34533b&p=1565247&l=120550&s=1&k=DdK23gAAAAA=&i=gf00rMjy89-g&v=44237561424281710040017&turl="], "curl": "http://ssxd.mediav.com/s?type=2&r=20&pinfo=&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&price=AAAAAFk+C9oAAAAAAAeTu1p/gsdXul6zQeMu3w==&finfo=DAABCAABAAABvggAAgAAADYEAAM/f/Lkjopx3gAIAAIAAAADCgADPra+UTCr9hUIAAQAAAA2BgAGLCMIAAgARA3gCgAJAAAAAACGABIGAAoAAAA&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=FZDlMhWok9IBFbqM1A4ViqHrRxUEFSIW9puwwxUWzJPVuryU37Z9NAIWpICwCCUGFcPgoLsDFfABFQAA&clickid=0&csign=70df286fcbe7a60b&url=http%3A%2F%2Fwww%2Ehejianzhiyang%2Ecom", "desc": "合建志洋房屋装修,免费量房验房,297项报价审核,价格透明0增项,直击价格底线,省钱30%。", "img": "http://s3m.mediav.com/galileo/dcb56800ac87350cbdbef62e69704032.jpg", "imptk": ["http://ssxd.mediav.com/s?type=1&r=20&tid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&finfo=DAABCAABAAABvggAAgAAADYEAAM/f/Lkjopx3gAIAAIAAAADCgADPra+UTCr9hUIAAQAAAA2BgAGLCMIAAgARA3gCgAJAAAAAACGABIGAAoAAAA&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=FZDlMhWok9IBFbqM1A4ViqHrRxUEFSIW9puwwxUWzJPVuryU37Z9NAIWpICwCCUGFcPgoLsDFfABFQAA&ds=1&price=AAAAAFk+C9oAAAAAAAeTu1p/gsdXul6zQeMu3w==", "http://max-l.mediav.com/rtb?type=2&d=100&b=116628b68d34533b&p=1565247&l=120550&s=1&w=AAAAAFk+C9oAAAAAAAeT5nMDruS2t1FfUI79sA==&k=DdK23gAAAAA=&i=gf00rMjy89-g&v=44237561424281710040017"], "slot": 1, "src": "合建志洋", "title": "北京2室2厅这样装 ，造价还不到5万！", "type": 2 }, { "assets": [{ "curl": "http://ssxd.mediav.com/s?type=2&r=20&pinfo=&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&price=AAAAAFk+C9oAAAAAAAeU9Gi6nN+x6ZENBjWLfg==&finfo=DAABCAABAAABuAgAAgAAAKgEAAM/ZFyhqychWgAIAAIAAAADCgADPrbQgv9GdPIIAAQAAACxBgAGH4kIAAgAQyOACgAJAAAAAACGABIGAAoAAAA&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=FdziLxWIzscBFcjyhg4V1I7zRhUGFSIWtLDh0BQWzJP/iNCg6LZ9NAQWpICwCCUGFYC4mo4HFf4EFQAA&clickid=74343338001&csign=b381a226f59d8d04&url=http%3A%2F%2Fbj%2Esunlandzk%2Ecom%2Fzn%2F360%2Ddsp%2Fpc%2Fmba2%2Findex%2Eself.html%3FMBA%2D360gdt%2D0411%2D1", "img": "http://s3m.mediav.com/galileo/efac38a32c651ea78f9f840b41613724.jpg" }, { "curl": "http://ssxd.mediav.com/s?type=2&r=20&pinfo=&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&price=AAAAAFk+C9oAAAAAAAeU9Gi6nN+x6ZENBjWLfg==&finfo=DAABCAABAAABuAgAAgAAAKgEAAM/ZFyhqychWgAIAAIAAAADCgADPrbQgv9GdPIIAAQAAACxBgAGH4kIAAgAQyOACgAJAAAAAACGABIGAAoAAAA&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=FdziLxWIzscBFcjyhg4V1I7zRhUGFSIWtLDh0BQWzJP/iNCg6LZ9NAQWpICwCCUGFYC4mo4HFf4EFQAA&clickid=74343338002&csign=b381a226f59d8d04&url=http%3A%2F%2Fbj%2Esunlandzk%2Ecom%2Fzn%2F360%2Ddsp%2Fpc%2Fmba2%2Findex%2Ehtml%3FMBA%2D360gdt%2D0411%2D1", "img": "http://s3m.mediav.com/galileo/42e42f17044d0eab88ca9a50cacd3880.jpg" }, { "curl": "http://ssxd.mediav.com/s?type=2&r=20&pinfo=&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&price=AAAAAFk+C9oAAAAAAAeU9Gi6nN+x6ZENBjWLfg==&finfo=DAABCAABAAABuAgAAgAAAKgEAAM/ZFyhqychWgAIAAIAAAADCgADPrbQgv9GdPIIAAQAAACxBgAGH4kIAAgAQyOACgAJAAAAAACGABIGAAoAAAA&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=FdziLxWIzscBFcjyhg4V1I7zRhUGFSIWtLDh0BQWzJP/iNCg6LZ9NAQWpICwCCUGFYC4mo4HFf4EFQAA&clickid=74343338003&csign=b381a226f59d8d04&url=http%3A%2F%2Fbj%2Esunlandzk%2Ecom%2Fzn%2F360%2Ddsp%2Fpc%2Fmba2%2Findex%2Ehtml%3FMBA%2D360gdt%2D0411%2D1", "img": "http://s3m.mediav.com/galileo/55ca86b53714ae7e26443177c9b1eaa8.jpg" }, { "curl": "http://ssxd.mediav.com/s?type=2&r=20&pinfo=&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&price=AAAAAFk+C9oAAAAAAAeU9Gi6nN+x6ZENBjWLfg==&finfo=DAABCAABAAABuAgAAgAAAKgEAAM/ZFyhqychWgAIAAIAAAADCgADPrbQgv9GdPIIAAQAAACxBgAGH4kIAAgAQyOACgAJAAAAAACGABIGAAoAAAA&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=FdziLxWIzscBFcjyhg4V1I7zRhUGFSIWtLDh0BQWzJP/iNCg6LZ9NAQWpICwCCUGFYC4mo4HFf4EFQAA&clickid=74343338004&csign=b381a226f59d8d04&url=http%3A%2F%2Fbj%2Esunlandzk%2Ecom%2Fzn%2F360%2Ddsp%2Fpc%2Fmba2%2Findex%2Ehtml%3FMBA%2D360gdt%2D0411%2D1", "img": "http://s3m.mediav.com/galileo/5094d2e1eabfe60bf493aa96fbb9dd7c.jpg" }], "clktk": ["http://max-l.mediav.com/rtb?type=3&d=100&b=116628b68d34533b&p=1565247&l=120550&s=2&k=DdK23gAAAAA=&i=gd00rMjy89as&v=44237561424281710040017&turl="], "curl": "http://ssxd.mediav.com/s?type=2&r=20&pinfo=&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&price=AAAAAFk+C9oAAAAAAAeU9Gi6nN+x6ZENBjWLfg==&finfo=DAABCAABAAABuAgAAgAAAKgEAAM/ZFyhqychWgAIAAIAAAADCgADPrbQgv9GdPIIAAQAAACxBgAGH4kIAAgAQyOACgAJAAAAAACGABIGAAoAAAA&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=FdziLxWIzscBFcjyhg4V1I7zRhUGFSIWtLDh0BQWzJP/iNCg6LZ9NAQWpICwCCUGFYC4mo4HFf4EFQAA&clickid=0&csign=b381a226f59d8d04&url=http%3A%2F%2Fbj%2Esunlandzk%2Ecom%2Fzn%2F360%2Ddsp%2Fpc%2Fmba2%2Findex%2Ehtml%3FMBA%2D360gdt%2D0411%2D1", "desc": "孩子上学，是我们现在要靠考虑的问题了！只有落户北京，才能在北京高考，成就孩子赢在人生起点!", "img": "http://s3m.mediav.com/galileo/efac38a32c651ea78f9f840b41613724.jpg", "imptk": ["http://ssxd.mediav.com/s?type=1&r=20&tid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&finfo=DAABCAABAAABuAgAAgAAAKgEAAM/ZFyhqychWgAIAAIAAAADCgADPrbQgv9GdPIIAAQAAACxBgAGH4kIAAgAQyOACgAJAAAAAACGABIGAAoAAAA&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=FdziLxWIzscBFcjyhg4V1I7zRhUGFSIWtLDh0BQWzJP/iNCg6LZ9NAQWpICwCCUGFYC4mo4HFf4EFQAA&ds=2&price=AAAAAFk+C9oAAAAAAAeU9Gi6nN+x6ZENBjWLfg==", "http://max-l.mediav.com/rtb?type=2&d=100&b=116628b68d34533b&p=1565247&l=120550&s=2&w=AAAAAFk+C9oAAAAAAAeVGyR+Go+ULcqXEbYQ5Q==&k=DdK23gAAAAA=&i=gd00rMjy89as&v=44237561424281710040017"], "slot": 2, "src": "尚德机构", "title": "考个MBA，落户北京，方便孩子上学！", "imgWidth": 100, "imgHeight": 100, "type": 2 }, { "clktk": ["http://max-l.mediav.com/rtb?type=3&d=100&b=116628b68d34533b&p=1565247&l=120550&s=3&k=DdK23gAAAAA=&i=gX_0rMjy89Rv&v=44237561424281710040017&turl="], "curl": "http://ssxd.mediav.com/s?type=2&r=20&pinfo=&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&price=AAAAAFk+C9oAAAAAAAeWDKBwXpx4C+itTgaEdw==&finfo=DAABCAABAAABnwgAAgAAASgEAAM/Uo5/Xkvw/wAIAAIAAAADCgADPrbZmuhLU0AIAAQAAAFuBgAGLCMIAAgAP1LwCgAJAAAAAACGABIGAAoAAAA&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=Fb6JMxWu9NEBFYLV0g4V5J/kRxUEFRwW9MK+yxUWzJOU8Nnm7LZ9NAYWpICwCCUGFe3EhNwCFfQBFQAA&clickid=0&csign=5ef2f36e5d7495a8&url=http%3A%2F%2Fwww%2Ezhaoqiye123%2Ecn", "desc": "专业卷帘门生产，经营各种卷帘门。工业提升门、伸缩门、防火门。防盗门等，免费上门安装，多年经营经验信誉保障！", "img": "http://s3m.mediav.com/galileo/29a035e1b5a1e54993ae72a21ca76058.jpg", "imptk": ["http://ssxd.mediav.com/s?type=1&r=20&tid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&finfo=DAABCAABAAABnwgAAgAAASgEAAM/Uo5/Xkvw/wAIAAIAAAADCgADPrbZmuhLU0AIAAQAAAFuBgAGLCMIAAgAP1LwCgAJAAAAAACGABIGAAoAAAA&mv_ref=www%2Ebtime%2Ecom&enup=CAAB2h50CggAAgp0HtoA&mvid=NDQyMzc1NjE0MjQyODE3MTAwNDAwMTc&bid=116628b68d34533b&ugi=FczbDhWOnkBMFQIVKBUAFQAAFf7ivfMMAA&uai=Ff6IvwElAhUCFsyTwNOyztq2fRXuCCWQm8nACAA&ubi=Fb6JMxWu9NEBFYLV0g4V5J/kRxUEFRwW9MK+yxUWzJOU8Nnm7LZ9NAYWpICwCCUGFe3EhNwCFfQBFQAA&ds=3&price=AAAAAFk+C9oAAAAAAAeWDKBwXpx4C+itTgaEdw==", "http://max-l.mediav.com/rtb?type=2&d=100&b=116628b68d34533b&p=1565247&l=120550&s=3&w=AAAAAFk+C9oAAAAAAAeWMuuWdun2UOv76QQmPw==&k=DdK23gAAAAA=&i=gX_0rMjy89Rv&v=44237561424281710040017"], "slot": 3, "src": "恒达晟泰", "title": "专业卷帘门，就找北京通达门业！品质保障！", "type": 1 }], "reqtimes": "1" };
                    // 视频数据
                    // if (self.page < 4) {
                    // sData = { "ads": [{ "clktk": ["http://max-l.mediav.com/rtb?type=3&d=100&b=12c1b6d7dfea1267&p=2204128&l=1091174&s=1&k=3MZI7AAAAAA=&i=8mFvfHuE6A4b&v=46131766912311030110018&x=__OFFSET_X__&y=__OFFSET_Y__&st=__EVENT_TIME_START__&et=__EVENT_TIME_END__&tc=&turl="], "curl": "http://ssxd.mediav.com/s?type=2&r=20&mv_ref=pc6.m.qss.test.so.com&enup=CAABCssVCggAAgoVywoA&mvid=NDYxMzE3NjY5MTIzMTEwMzAxMTAwMTg&bid=12c1b6d7dfea1267&price=AAAAAFwE3N8AAAAAAAbeSfc9D8OfzMiTp+VGVg==&finfo=DAABCAABAAAJQAgAAgAAAAIEAAM/gqcuUpGqvAAIAAIAAAADCgADPGZdEBDGSP8IAAQAAAEECAAIAWlUAAoACQAAAAAAAgAUBgAKAAAGAA0biwA&ugi=FcyZhQEVzpRmTBXWChUAFQAVAAAV0t/Y5QslyAEA&uai=FcCHjQIlAhUEFtDjpsiK/qnmeBWOCyX5/f3/BCUAFRoA&ubi=FZDmJBW0p7QCFcSBzBYV4KjqVhUGFRAWmo3H+hQW0OO7r5TEruZ4NAIWqKAQJQYVnOrzuA0VngEVACQKFpDmJAA&clickid=0&cpx=__OFFSET_X__&cpy=__OFFSET_Y__&cs=__EVENT_TIME_START__&ce=__EVENT_TIME_END__&ldtype=2&csign=209d24e71f4fb5df&csign2=OpO4Um1u22-=&url=http%3A%2F%2Fy.code.17tanwan.com%2Fhtmlcode%2F27399.html", "desc": "双巨星代言！2017火爆游戏，装备全靠打，可交易，上线VIP，太子刘烨、山鸡等你来1区！", "duration": 15, "img": "http://s3m.mediav.com/galileo/301448-7d65d314a9c53cca10954cdc076e24c6.gif", "imgh": 720, "imgw": 1280, "imptk": ["http://ssxd.mediav.com/s?type=1&r=20&tid=NDYxMzE3NjY5MTIzMTEwMzAxMTAwMTg&finfo=DAABCAABAAAJQAgAAgAAAAIEAAM/gqcuUpGqvAAIAAIAAAADCgADPGZdEBDGSP8IAAQAAAEECAAIAWlUAAoACQAAAAAAAgAUBgAKAAAGAA0biwA&mv_ref=pc6.m.qss.test.so.com&enup=CAABCssVCggAAgoVywoA&mvid=NDYxMzE3NjY5MTIzMTEwMzAxMTAwMTg&bid=12c1b6d7dfea1267&ugi=FcyZhQEVzpRmTBXWChUAFQAVAAAV0t/Y5QslyAEA&uai=FcCHjQIlAhUEFtDjpsiK/qnmeBWOCyX5/f3/BCUAFRoA&ubi=FZDmJBW0p7QCFcSBzBYV4KjqVhUGFRAWmo3H+hQW0OO7r5TEruZ4NAIWqKAQJQYVnOrzuA0VngEVACQKFpDmJAA&ds=1&price=AAAAAFwE3N8AAAAAAAbeSfc9D8OfzMiTp+VGVg==", "http://max-l.mediav.com/rtb?type=2&d=100&b=12c1b6d7dfea1267&p=2204128&l=1091174&s=1&z=1&w=AAAAAFwE3N8AAAAAAAbebJTUfr0DbsuCegSOMg==&k=3MZI7AAAAAA=&i=8mFvfHuE6A4b&v=46131766912311030110018"], "slot": 1, "src": "贪玩游戏", "title": "别再玩假传奇了，这款爆率+99999倍，找到充值入口算我输！", "type": 4, "video": "https://live-s3m.mediav.com/nativevideo/387432-89ba3b8d744c2bd153241811df92aaa5-bit_cloud768.mp4" }, { "clktk": ["http://max-l.mediav.com/rtb?type=3&d=100&b=12c1b6d7dfea1267&p=2204128&l=1091174&s=1&k=3MZI7AAAAAA=&i=8mFvfHuE6A4b&v=46131766912311030110018&x=__OFFSET_X__&y=__OFFSET_Y__&st=__EVENT_TIME_START__&et=__EVENT_TIME_END__&tc=&turl="], "curl": "http://ssxd.mediav.com/s?type=2&r=20&mv_ref=pc6.m.qss.test.so.com&enup=CAABCssVCggAAgoVywoA&mvid=NDYxMzE3NjY5MTIzMTEwMzAxMTAwMTg&bid=12c1b6d7dfea1267&price=AAAAAFwE3N8AAAAAAAbeSfc9D8OfzMiTp+VGVg==&finfo=DAABCAABAAAJQAgAAgAAAAIEAAM/gqcuUpGqvAAIAAIAAAADCgADPGZdEBDGSP8IAAQAAAEECAAIAWlUAAoACQAAAAAAAgAUBgAKAAAGAA0biwA&ugi=FcyZhQEVzpRmTBXWChUAFQAVAAAV0t/Y5QslyAEA&uai=FcCHjQIlAhUEFtDjpsiK/qnmeBWOCyX5/f3/BCUAFRoA&ubi=FZDmJBW0p7QCFcSBzBYV4KjqVhUGFRAWmo3H+hQW0OO7r5TEruZ4NAIWqKAQJQYVnOrzuA0VngEVACQKFpDmJAA&clickid=0&cpx=__OFFSET_X__&cpy=__OFFSET_Y__&cs=__EVENT_TIME_START__&ce=__EVENT_TIME_END__&ldtype=2&csign=209d24e71f4fb5df&csign2=OpO4Um1u22-=&url=http%3A%2F%2Fy.code.17tanwan.com%2Fhtmlcode%2F27399.html", "desc": "双巨星代言！2017火爆游戏，装备全靠打，可交易，上线VIP，太子刘烨、山鸡等你来1区！", "duration": 15, "img": "http://s3m.mediav.com/galileo/301448-7d65d314a9c53cca10954cdc076e24c6.gif", "imgh": 720, "imgw": 1280, "imptk": ["http://ssxd.mediav.com/s?type=1&r=20&tid=NDYxMzE3NjY5MTIzMTEwMzAxMTAwMTg&finfo=DAABCAABAAAJQAgAAgAAAAIEAAM/gqcuUpGqvAAIAAIAAAADCgADPGZdEBDGSP8IAAQAAAEECAAIAWlUAAoACQAAAAAAAgAUBgAKAAAGAA0biwA&mv_ref=pc6.m.qss.test.so.com&enup=CAABCssVCggAAgoVywoA&mvid=NDYxMzE3NjY5MTIzMTEwMzAxMTAwMTg&bid=12c1b6d7dfea1267&ugi=FcyZhQEVzpRmTBXWChUAFQAVAAAV0t/Y5QslyAEA&uai=FcCHjQIlAhUEFtDjpsiK/qnmeBWOCyX5/f3/BCUAFRoA&ubi=FZDmJBW0p7QCFcSBzBYV4KjqVhUGFRAWmo3H+hQW0OO7r5TEruZ4NAIWqKAQJQYVnOrzuA0VngEVACQKFpDmJAA&ds=1&price=AAAAAFwE3N8AAAAAAAbeSfc9D8OfzMiTp+VGVg==", "http://max-l.mediav.com/rtb?type=2&d=100&b=12c1b6d7dfea1267&p=2204128&l=1091174&s=1&z=1&w=AAAAAFwE3N8AAAAAAAbebJTUfr0DbsuCegSOMg==&k=3MZI7AAAAAA=&i=8mFvfHuE6A4b&v=46131766912311030110018"], "slot": 1, "src": "贪玩游戏", "title": "别再玩假传奇了，这款爆率+99999倍，找到充值入口算我输！", "type": 4, "video": "http://s3m.mediav.com/galileo/301448-638768f74195b505a11653d0f23f0a6f.mp4" }], "reqtimes": "2" }
                    // }
                    // 大图广告
                    // sData = { "ads": [{ "clktk": ["http://max-l.mediav.com/rtb?type=3&d=100&b=12c1c0fa3958988d&p=2259517&l=1091174&s=1&k=dVqH0wAAAAA=&i=BITvc3xU6ACO&v=20900581404281803120018&x=__OFFSET_X__&y=__OFFSET_Y__&st=__EVENT_TIME_START__&et=__EVENT_TIME_END__&tc=&turl="], "curl": "http://ssxd.mediav.com/s?type=2&r=20&mv_ref=pc6.m.qss.test.so.com&enup=CAABCssVBwgAAgcVywoA&mvid=MjA5MDA1ODE0MDQyODE4MDMxMjAwMTg&bid=12c1c0fa3958988d&price=AAAAAFwFBWgAAAAAAAwx4j9PUYXxZ45j6UlySQ==&finfo=DAABCAABAAAEaQgAAgAAAAMEAAM/ZIwgQJewBQAIAAIAAAADCgADYzXPaR6W0PwIAAQAAAEsCAAIAKxFkAoACQAAAAAAAgAUBgAKAAAGAA0fFQA&ugi=FcyZhQEVzpRmTBXWChUAFQAVAAAV0t/Y5QslyAEA&uai=FfrokwIlAhUEFrCN2uamlOO1xgEV8ggli+PujAwlABUaAA&ubi=Fdb2PxX8uKoCFarbmxYVnsOVVhUGFRwW9JfIxxYWsI3vzbDa57XGATQCFqiAECUGFYiXyu0DFZ4BFQAkAhaP98rp9cnekr0BAA&clickid=0&cpx=__OFFSET_X__&cpy=__OFFSET_Y__&cs=__EVENT_TIME_START__&ce=__EVENT_TIME_END__&ldtype=2&csign=3162b1b5d23acfaa&csign2=BxefodFJjUY=&url=https%3A%2F%2Fwww.ledctl.com%2F37jpdk3c%2Fax54pn4%2F45tl453.html%3Fru7hwk%3D3bj1zzo_", "desc": "新区开区一秒，玩家破百万，服务器瞬间挤爆，20倍爆率，注册还送vip，装备不花一分钱，平民玩家必玩", "img": "http://s3m.mediav.com/galileo/523691-cc9c50a6386d786c86f324337459fc1f.gif", "imgh": 220, "imgw": 660, "imptk": ["http://ssxd.mediav.com/s?type=1&r=20&tid=MjA5MDA1ODE0MDQyODE4MDMxMjAwMTg&finfo=DAABCAABAAAEaQgAAgAAAAMEAAM/ZIwgQJewBQAIAAIAAAADCgADYzXPaR6W0PwIAAQAAAEsCAAIAKxFkAoACQAAAAAAAgAUBgAKAAAGAA0fFQA&mv_ref=pc6.m.qss.test.so.com&enup=CAABCssVBwgAAgcVywoA&mvid=MjA5MDA1ODE0MDQyODE4MDMxMjAwMTg&bid=12c1c0fa3958988d&ugi=FcyZhQEVzpRmTBXWChUAFQAVAAAV0t/Y5QslyAEA&uai=FfrokwIlAhUEFrCN2uamlOO1xgEV8ggli+PujAwlABUaAA&ubi=Fdb2PxX8uKoCFarbmxYVnsOVVhUGFRwW9JfIxxYWsI3vzbDa57XGATQCFqiAECUGFYiXyu0DFZ4BFQAkAhaP98rp9cnekr0BAA&ds=1&price=AAAAAFwFBWgAAAAAAAwx4j9PUYXxZ45j6UlySQ==", "http://max-l.mediav.com/rtb?type=2&d=100&b=12c1c0fa3958988d&p=2259517&l=1091174&s=1&z=1&w=AAAAAFwFBWgAAAAAAAwyBvBE0NZGmTsqde3ZJA==&k=dVqH0wAAAAA=&i=BITvc3xU6ACO&v=20900581404281803120018"], "slot": 1, "src": "红月传说 · 顶新", "title": "如果你连1元都不想充，这传奇要玩，10分钟三转", "type": 3 }], "reqtimes": "3" };
                    // 方图
                    // sData = { ads: [{ assets: [{ curl: "http://ssxd.mediav.com/s?type=2&r=20&pinfo=6_34593656826&mv_ref=pc6.m.qss.test.so.com&enup=CAABCssY7QgAAu0YywoA&mvid=NzY3MDU1NjE3NDEzMjE0MDUxMjAwMTg&bid=12c2b3834def6f25&ugi=FaLOFBXkkEZMFdYKFQAVABUAABXS39jlCyXIAQA&uai=FaaKgAIlAhUEFsDWpYGN94W1zgEV8Aclxs2L0QIlABUaAA&ubi=FcyPMhXUq6gCFbD0jRYVrOH+VRUGFRIWgOHDuBUWwNbPz6CDj7XOATQCFrCAGCUAFaun7voFFaIEFQA2AAA&clickid=90167382001&cpx=__OFFSET_X__&cpy=__OFFSET_Y__&cs=__EVENT_TIME_START__&ce=__EVENT_TIME_END__&ldtype=2&csign=e28e73ab9dfadfdd&csign2=aOwqMrH7rWo=&url=https%3A%2F%2Funion-click.jd.com%2Fsem.php%3Fsource%3D360-dsp%26unionId%3D262767352%26siteId%3D360dsp_%7Bcreativeid%7D%26to%3Dhttps%253A%252F%252Fitem.jd.com%252F34593656826.html", desc: "途酷正品 途酷钓鱼伞专用伞布 伞面撑开直径1.8m/2.0m伞布 包邮 直径1.8m（单根伞骨105cm）", img: "http://p18.qhimgs3.com/dr/240_240_/t01aaa76b158d9999aa.jpg?t=1543478425", imgh: 180, imgw: 180 }, { curl: "http://ssxd.mediav.com/s?type=2&r=20&pinfo=6_28830484283&mv_ref=pc6.m.qss.test.so.com&enup=CAABCssY7QgAAu0YywoA&mvid=NzY3MDU1NjE3NDEzMjE0MDUxMjAwMTg&bid=12c2b3834def6f25&ugi=FaLOFBXkkEZMFdYKFQAVABUAABXS39jlCyXIAQA&uai=FaaKgAIlAhUEFsDWpYGN94W1zgEV8Aclxs2L0QIlABUaAA&ubi=FcyPMhXUq6gCFbD0jRYVrOH+VRUGFRIWgOHDuBUWwNbPz6CDj7XOATQCFrCAGCUAFaun7voFFaIEFQA2AAA&clickid=90167382002&cpx=__OFFSET_X__&cpy=__OFFSET_Y__&cs=__EVENT_TIME_START__&ce=__EVENT_TIME_END__&ldtype=2&csign=e28e73ab9dfadfdd&csign2=aOwqMrH7rWo=&url=https%3A%2F%2Funion-click.jd.com%2Fsem.php%3Fsource%3D360-dsp%26unionId%3D262767352%26siteId%3D360dsp_%7Bcreativeid%7D%26to%3Dhttps%253A%252F%252Fitem.jd.com%252F28830484283.html", desc: "中润 4.4平衡se215 535 im70 ls50 ue900 mmcx ie80s耳机升级线 2.5mm平衡镀银 黑色 森海塞尔ie80/ie80s系列", img: "http://p18.qhimgs3.com/dr/240_240_/t016771cfc66f9824ca.jpg?t=1532505668", imgh: 180, imgw: 180 }, { curl: "http://ssxd.mediav.com/s?type=2&r=20&pinfo=6_11183940133&mv_ref=pc6.m.qss.test.so.com&enup=CAABCssY7QgAAu0YywoA&mvid=NzY3MDU1NjE3NDEzMjE0MDUxMjAwMTg&bid=12c2b3834def6f25&ugi=FaLOFBXkkEZMFdYKFQAVABUAABXS39jlCyXIAQA&uai=FaaKgAIlAhUEFsDWpYGN94W1zgEV8Aclxs2L0QIlABUaAA&ubi=FcyPMhXUq6gCFbD0jRYVrOH+VRUGFRIWgOHDuBUWwNbPz6CDj7XOATQCFrCAGCUAFaun7voFFaIEFQA2AAA&clickid=90167382003&cpx=__OFFSET_X__&cpy=__OFFSET_Y__&cs=__EVENT_TIME_START__&ce=__EVENT_TIME_END__&ldtype=2&csign=e28e73ab9dfadfdd&csign2=aOwqMrH7rWo=&url=https%3A%2F%2Funion-click.jd.com%2Fsem.php%3Fsource%3D360-dsp%26unionId%3D262767352%26siteId%3D360dsp_%7Bcreativeid%7D%26to%3Dhttps%253A%252F%252Fitem.jd.com%252F11183940133.html", desc: "帝翔LED水底灯水池灯七彩变色水下灯泳池水景喷泉灯不锈钢鱼缸射灯3W6W12W15W室外庭院灯 暖白光 3W AC24V", img: "http://p20.qhimgs3.com/dr/240_240_/t0152c893d43bc22b91.jpg?t=1541232052", imgh: 180, imgw: 180 }, { curl: "http://ssxd.mediav.com/s?type=2&r=20&pinfo=6_35406685916&mv_ref=pc6.m.qss.test.so.com&enup=CAABCssY7QgAAu0YywoA&mvid=NzY3MDU1NjE3NDEzMjE0MDUxMjAwMTg&bid=12c2b3834def6f25&ugi=FaLOFBXkkEZMFdYKFQAVABUAABXS39jlCyXIAQA&uai=FaaKgAIlAhUEFsDWpYGN94W1zgEV8Aclxs2L0QIlABUaAA&ubi=FcyPMhXUq6gCFbD0jRYVrOH+VRUGFRIWgOHDuBUWwNbPz6CDj7XOATQCFrCAGCUAFaun7voFFaIEFQA2AAA&clickid=90167382004&cpx=__OFFSET_X__&cpy=__OFFSET_Y__&cs=__EVENT_TIME_START__&ce=__EVENT_TIME_END__&ldtype=2&csign=e28e73ab9dfadfdd&csign2=aOwqMrH7rWo=&url=https%3A%2F%2Funion-click.jd.com%2Fsem.php%3Fsource%3D360-dsp%26unionId%3D262767352%26siteId%3D360dsp_%7Bcreativeid%7D%26to%3Dhttps%253A%252F%252Fitem.jd.com%252F35406685916.html", desc: "【品牌精选】富贵鸟秋冬2018新款男士百搭防寒保暖棉服厚款带帽棉衣男棉外套 818红色 M", img: "http://p20.qhimgs3.com/dr/240_240_/t015e0efcb386867c4f.jpg?t=1542614425", imgh: 180, imgw: 180 }], clktk: ["http://max-l.mediav.com/rtb?type=3&d=100&b=12c2b3834def6f25&p=2097811&l=168849&s=1&k=JMvvYQAAAAA=&i=C5ZU84gm69N9&v=76705561741321405120018&x=__OFFSET_X__&y=__OFFSET_Y__&st=__EVENT_TIME_START__&et=__EVENT_TIME_END__&tc=&turl="], curl: "http://ssxd.mediav.com/s?type=2&r=20&pinfo=6_34593656826&mv_ref=pc6.m.qss.test.so.com&enup=CAABCssY7QgAAu0YywoA&mvid=NzY3MDU1NjE3NDEzMjE0MDUxMjAwMTg&bid=12c2b3834def6f25&ugi=FaLOFBXkkEZMFdYKFQAVABUAABXS39jlCyXIAQA&uai=FaaKgAIlAhUEFsDWpYGN94W1zgEV8Aclxs2L0QIlABUaAA&ubi=FcyPMhXUq6gCFbD0jRYVrOH+VRUGFRIWgOHDuBUWwNbPz6CDj7XOATQCFrCAGCUAFaun7voFFaIEFQA2AAA&clickid=0&cpx=__OFFSET_X__&cpy=__OFFSET_Y__&cs=__EVENT_TIME_START__&ce=__EVENT_TIME_END__&ldtype=2&csign=e28e73ab9dfadfdd&csign2=aOwqMrH7rWo=&url=https%3A%2F%2Funion-click.jd.com%2Fsem.php%3Fsource%3D360-dsp%26unionId%3D262767352%26siteId%3D360dsp_%7Bcreativeid%7D%26to%3Dhttps%253A%252F%252Fitem.jd.com%252F34593656826.html", desc: "途酷正品 途酷钓鱼伞专用伞布 伞面撑开直径1.8m/2.0m伞布 包邮 直径1.8m（单根伞骨105cm）", img: "http://jx.cdn.qhstatic.com/cimg.jpg?size=180x100&tid=415&aid=410598&timg=http%3A%2F%2Fp18.qhimgs3.com%2Fdr%2F240_240_%2Ft01aaa76b158d9999aa.jpg%3Ft%3D1543478425&price=50&button=&logo=&pn=%E9%80%94%E9%85%B7%E6%AD%A3%E5%93%81+%E9%80%94%E9%85%B7%E9%92%93%E9%B1%BC%E4%BC%9E%E4%B8%93%E7%94%A8%E4%BC%9E%E5%B8%83+%E4%BC%9E%E9%9D%A2%E6%92%91%E5%BC%80%E7%9B%B4%E5%BE%841.8m%2F2.0m%E4%BC%9E%E5%B8%83+%E5%8C%85%E9%82%AE+%E7%9B%B4%E5%BE%841.8m%EF%BC%88%E5%8D%95%E6%A0%B9%E4%BC%9E%E9%AA%A8105cm%EF%BC%89&b=0&ver=1542355914", imgh: 100, imgw: 180, imptk: ["http://ssxd.mediav.com/s?type=1&r=20&tid=NzY3MDU1NjE3NDEzMjE0MDUxMjAwMTg&finfo=DAABCAABAAAAAAgAAgAAAAAACAACAAAAAAoAA2c1Hg03C6iJCAAEAAAAAAgACAAAJxAKAAkAAAAAAAMAGAA&mv_ref=pc6.m.qss.test.so.com&enup=CAABCssY7QgAAu0YywoA&mvid=NzY3MDU1NjE3NDEzMjE0MDUxMjAwMTg&bid=12c2b3834def6f25&ugi=FaLOFBXkkEZMFdYKFQAVABUAABXS39jlCyXIAQA&uai=FaaKgAIlAhUEFsDWpYGN94W1zgEV8Aclxs2L0QIlABUaAA&ubi=FcyPMhXUq6gCFbD0jRYVrOH+VRUGFRIWgOHDuBUWwNbPz6CDj7XOATQCFrCAGCUAFaun7voFFaIEFQA2AAA&ds=1&price=AAAAAFwHco0AAAAAAAshz25kcPiesOLetQCNBg==", "http://max-l.mediav.com/rtb?type=2&d=100&b=12c2b3834def6f25&p=2097811&l=168849&s=1&z=1&w=AAAAAFwHco0AAAAAAAsiFz3OrsmF1r7fMPj8Bg==&k=JMvvYQAAAAA=&i=C5ZU84gm69N9&v=76705561741321405120018"], slot: 1, src: "热门推荐", title: "别再花冤枉钱了！这里超便宜！", type: 2 }], reqtimes: "1" };

                    self.page++;
                    // console.log('%cSad.data.length:', 'color:#0f0;text-shadow: 1px 1px 0 rgba(0,0,0,1);', sData.ads && sData.ads.length || 0);
                    if (sData && sData.ads && sData.ads.length > 0) {
                        self.clearUpData(sData.ads);
                        self.insert(self);
                    }
                }
            });
        }
    }
})();